﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace DecisionFramework.Logging
{
	/// <summary>
	/// Specifies the interface for logging to a "Windows 7" 
    /// like channel.
	/// </summary>
	/// <remarks> 
	/// Author: Greg Cowin
	/// </remarks>
	public interface ILogChannel
	{
		/// <summary>
		/// The channel associated with the log channel: Admin, Operational, Analytics, Debug.
		/// </summary>
		IChannel Channel { get; } 

		/// <summary>
		/// The name of the component that will be logged such as class name
        /// or component.
		/// </summary>
		string Component { get; }

		/// <summary>
		/// Write the given app event to the log.
		/// </summary>
		/// <param name="message">The message to log.</param>
		void WriteAppEvent(string message);

		/// <summary>
		/// Write the given app event with the given event type such as Critical, Error, Info, or Verbose.
		/// </summary>
		/// <param name="message">The app event to log.</param>
		/// <param name="eventType">The event type such as Critical, Error, Info, or Verbose.</param>
		void WriteAppEvent(string message, Severity eventType);

		/// <summary>
		/// Write the given app event.
		/// </summary>
		/// <param name="eventLog">The log entry to log.</param>
        void WriteAppEvent(AppEvent appEvent);

		/// <summary>
		/// Write the given app event with exception. The severity will be Error.
		/// </summary>
		/// <param name="message">The message to log.</param>
		/// <param name="e">The exception to log.</param>
		void WriteAppEvent(string message, Exception e);
	}
}
